﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace SpeedTest.ClassOrStruct
{
    class StructCreator
    {
        List<SmallStruct> structs;
        double abc;

        public void Init()
        {
            structs = new List<SmallStruct>();
            for (int i = 0; i < 10; i++)
            {
                structs.Add(new SmallStruct(50.0));
            }
        }

        public void doSomething()
        {
            // for statt foreach weil wir die Member von item verändern
            for (int i = 0; i < structs.Count - 1; i++)
            {
                abc = structs[i].A;
            }
        }
    }
}
